package com.runtime;

import com.base.Constant;
import com.base.Sprite;
import com.util.ImageUtil;

import java.awt.Graphics;
import java.awt.Image;

public class Background extends Sprite {


    private Image image;
    public Background() {
        init();
    }
    private void init(){
        //设置起始位置
        setX(0);
        setY(Constant.WINDOW_TOOLBAR_HEIGHT);
        image = ImageUtil.get("bg");
    }

    @Override
    public void draw(Graphics g) {
        g.drawImage(image,getX(),getY(),null);
    }

}
